proc ping:reply {from type fr rtime ok child} {

	if {$ok!="ERR"} {

		set ctime [clock clicks -milliseconds]
		set ptime [expr $ctime-$rtime]
		set atime [expr $ptime/1000]
   
		if { $type=="chat"} {
			pm "$from" "ping from $fr $ptime millisecs ($atime secs)"
		} else {
			gm "$from" "ping from $fr $ptime millisecs ($atime secs)"
		}
	}
}
